package com.iknight.mgr.core.constant;

/**
 * Created by jeryzym on 2017/9/22.
 */
public class IkgExcelParseConstant {
    /**
     * xml中验证规则的名称name 非空校验
     */
    public static final String RULE_NAME_NULLABLE = "nullable";

    /**
     *  重复校验
     */
    public static final String RULE_NAME_UNIQUE = "checkUnique";

    /**
     * 时间格式校验
     */
    public static final String RULE_DATE_FORMAT = "checkDateFormat";

    /**
     * 数据长度校验
     */
    public static final String RULE_MAX_LENGTH = "maxLength";

    /**
     * 数据长度校验
     */
    public static final String RULE_ID_CARD_NO = "checkIdCardNo";

    /**
     * 手机号码格式校验
     */
    public static final String RULE_PHONE_NO = "checkPhone";

    /**
     * excel中数据为空! v
     */
    public static final String ERROR_EXCEL_NULL = "excel中数据为空!<br>";

    /**
     * 模板格式校验提示信息
     */
    public static final String ERROR_EXCEL_COLUMN_NOT_EQUAL = "excel列数与模板不相符，请检查!<br>";

    /**
     * 数据类型错误提示信息
     */
    public static final String ERROR_EXCEL_DATA_TYPE = "数据类型错误";

    /**
     * 导入数据模板不符 提示信息
     */
    public static final String ERROR_EXCEL_TEMPLATE_TYPE = "导入数据与模板不符";

    /**
     * 时间格式 正则表达式
     */
    public static final String DATE_TIME_REXP = "^((\\d{2}(([02468][048])|([13579][26]))[\\-\\/\\s]?"
            + "((((0?[13578])|(1[02]))[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|"
            + "(((0?[469])|(11))[\\-\\/\\s]?((0?[1-9])|"
            + "([1-2][0-9])|(30)))|(0?2[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])))))|"
            + "(\\d{2}(([02468][1235679])|([13579][01345789]))[\\-\\/\\s]?((((0?[13578])|"
            + "(1[02]))[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|"
            + "(((0?[469])|(11))[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])|(30)))|"
            + "(0?2[\\-\\/\\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))))";

    /**
     * 整形数字类型校验
     */
    public static final String RULE_NUM_INT = "checkNumInt";

    /**
     *浮点数字类型校验
     */
    public static final String RULE_NUM_FLOAT = "checkNumFloat";
}
